#include "../include/ink_framework.h"
#include "../include/ink_module_mgr.h"

namespace ink
{

    framework& framework::instance()
    {
        static framework m_instance;
        return m_instance;
    }

    framework::framework()
    {
        module_mgr_ = new module_mgr;
    }

    void framework::register_module(const std::string& name, module_creator* creator )
    {
        module_mgr_->register_creator(name, creator);
    }

    module_i* framework::create_module( const std::string& module_name )
    {
        return module_mgr_->create_module(module_name);
    }
} // namespace ink